<?xml version='1.0' encoding='ISO-8859-1' ?>
<!DOCTYPE HTML>
<ui:composition 
	template="/dinamic/template/template.xhtml" 
	xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui">

	<ui:define name="conteudo">              
	    <h:form id="formLogin">
    	    <p:panel id="panelNovoUsuario" header="Login" >
    	    <p:growl id="messages" autoUpdate="true" />
	    	    <div align="center">
	                <h:panelGrid columns="2" cellpadding="5">
	
		                <h:outputLabel  styleClass="name" for="email" value="E-mail:*" />
	                    <p:inputText size="30" id="email" required="true" value="#{usuarioManagedBean.usuario.email}" requiredMessage="Informe o E-mail !"/>
	
	                    <h:outputLabel styleClass="name" for="senha" value="Senha:*"  />
	                    <p:password size="30" id="senha" required="true" value="#{usuarioManagedBean.usuario.senha}" requiredMessage="Informe a senha !"/>
	
	                  	<p:commandButton value="Registrar" action="#{usuarioManagedBean.cadastrar()}" ajax="false" />
	                    <p:commandButton value="Limpar" update="panelNovoUsuario" process="@this">  
	                    	<p:resetInput target="panelNovoUsuario" />  
	                    </p:commandButton>
	
	                </h:panelGrid>
	            </div>
        	</p:panel>
		</h:form>                              
	</ui:define>
</ui:composition>